home *** CD-ROM | disk | FTP | other *** search
/ Mac Power 1997 December / MACPOWER-1997-12.ISO.7z / MACPOWER-1997-12.ISO / AMUG / PROGRAMMING / Raven 1.2 Examples.sit / Raven 1.2 Examples / Quill / Source / RsrcPopupMenu.h < prev    next >
C/C++ Source or Header  |  1997-05-11  |  1KB  |  70 lines

  1. /*
  2.  *    File:        RsrcPopupMenu.h
  3.  *    Function:    A popup menu used for picking things like SPen and STextTrait resource.
  4.  *    Written by:    Jesse Jones
  5.  *
  6.  *  Copyright ゥ 1997 Jesse Jones. 
  7.  *    For conditions of distribution and use, see copyright notice in ZTypes.h  
  8.  *
  9.  *    Change History (most recent first):
  10.  *
  11.  *         <1>     5/11/97    JDJ        Created
  12.  */
  13.  
  14. #pragma once
  15.  
  16. #include <ZPopupMenu.h>
  17.  
  18.  
  19. // ===================================================================================
  20. //    class CRsrcPopupMenu
  21. // ===================================================================================
  22. class CRsrcPopupMenu : public TPopupMenu {
  23.     
  24.     typedef TPopupMenu Inherited;
  25.     
  26. //-----------------------------------
  27. //    Initialization/Destruction
  28. //
  29. public:
  30.     virtual               ~CRsrcPopupMenu();
  31.     
  32.                         CRsrcPopupMenu(const string& name, TView* superView, const TRect& frame, 
  33.                                           const string& title, short titleWidth, const string& mesg, 
  34.                                        ResID menuID);
  35.  
  36.     static     MReanimatable* Create(MReanimatable* parent);
  37.  
  38. //-----------------------------------
  39. //    New API
  40. //
  41. public:
  42.             ResID         GetID() const                {return mRsrcID;}
  43.  
  44.             void         SetID(ResID id);
  45.  
  46. //-----------------------------------
  47. //    Inherited API
  48. //
  49. protected:
  50.     virtual void         OnReanimated();
  51.  
  52.     virtual void        OnClickedControl();
  53.  
  54. //-----------------------------------
  55. //    Internal API
  56. //
  57. protected:
  58.             void         DoUpdateID();
  59.  
  60. //-----------------------------------
  61. //    Member data
  62. //
  63. private:
  64.     ResType        mRsrcType;
  65.     ResID        mRsrcID;
  66. };
  67.  
  68.  
  69.  
  70.